{% if not context.lp_active_blocks %}
<div class="col-xs">
{% endif %}

	<div class="lp_frontpage_articles article_view">
		{{ show_pagination() }}

		{% for article in context.lp_frontpage_articles %}
		<div class="col-xs-12 col-sm-6 col-md-{{ context.lp_frontpage_num_columns }}">
			<article class="roundframe{{ article.css_class ?? '' }}">
				{% if article.image %}
					{% if article.is_new %}
						<div class="new_hover">
							<div class="new_icon">
								<span class="new_posts">{{ txt.new }}</span>
							</div>
						</div>
					{% endif %}
					{% if article.can_edit %}
						<div class="info_hover">
							<div class="edit_icon">
								<a href="{{ article.edit_link }}">{{ icon('edit', txt.edit) }}</a>
							</div>
						</div>
					{% endif %}
					<div class="card_img"></div>
					<a href="{{ article.link }}">
						<div class="card_img_hover lazy" data-bg="{{ article.image }}"></div>
					</a>
				{% endif %}
				<div class="card_info">
					<span class="card_date smalltext">
						{% if article.section.name %}
							<a class="floatleft" href="{{ article.section.link }}">
								{{ icon('category') }}{{ article.section.name }}
							</a>
						{% endif %}
						{% if article.is_new and not article.image %}
							<span class="new_posts">
								{{ txt.new }}
							</span>
						{% endif %}
						{% if article.datetime %}
							<time class="floatright" datetime="{{ article.datetime }}">
								{{ icon('date') }}{{ article.date|raw }}
							</time>
						{% endif %}
					</span>
					<h3>
						<a href="{{ article.link }}">{{ article.title }}</a>
					</h3>
					{% if article.teaser %}
						<p>{{ article.teaser }}</p>
					{% endif %}
					<div>
						{% if article.category %}
							<span class="card_author">
								{{ icon('category') }}{{ article.category }}
							</span>
						{% endif %}
						{% if modSettings.lp_show_author and article.author %}
							{% if article.author.id and article.author.name %}
								<a class="card_author" href="{{ article.author.link }}">
									{{ icon('user') }}{{ article.author.name }}
								</a>
							{% else %}
								<span class="card_author">{{ txt.guest_title }}</span>
							{% endif %}
						{% endif %}
						{% if modSettings.lp_show_views_and_comments %}
							<span class="floatright">
								{% if article.views.num %}
									{{ icon('views', article.views.title) }}
									{{ article.views.num }}
								{% endif %}
								{% if article.views.after %}
									{{ article.views.after|raw }}
								{% endif %}
								{% if article.is_redirect %}
									{{ icon('redirect') }}
								{% endif %}
								{% if article.replies.num %}
									{{ icon('replies', article.replies.title) }}
									{{ article.replies.num }}
								{% endif %}
								{% if article.replies.after %}
									{{ article.replies.after|raw }}
								{% endif %}
							</span>
						{% endif %}
					</div>
				</div>
			</article>
		</div>
		{% endfor %}

		{{ show_pagination('bottom') }}
	</div>

{% if not context.lp_active_blocks %}
</div>
{% endif %}
